import request from "../utils/request";


// 总访问量
export const mrbirdApi = () => {
    return request('/index/mrbird')
}



// 获取用户列表
export const getUserApi = () => {
    return request('/user')
}
// 修改用户
export const modifyUserApi = (username, email, status, ssex, roleId, userId, deptId,description,mobile) => {
    return request(`/user/profile?username=${username}&email=${email}&status=${status}&ssex=${ssex}&roleId=${roleId}&userId=${userId}&deptId=${deptId}&description=${description}&mobile=${mobile}`, {
        method: 'PUT'
    })
}
// export const modifyUserApi = (username, email, status, ssex, roleId, userId, deptId,description,mobile) => {
//     return request(`/user?username=${username}&email=${email}&status=${status}&ssex=${ssex}&roleId=${roleId}&userId=${userId}&deptId=${deptId}&description=${description}&mobile=${mobile}`, {
//         method: 'PUT'
//     })
// }

// 获取mrbird用户信息
export const getCurUserApi = () => {
    return request('/user/mrbird')
}

// 获取所有用户数据列表
export const getAllUserListApi =()=>{
    return request('/user')
}

// 新增用户
export const addUserApi=(username,password,roleId,status,ssex,email,mobile,deptId)=>{
    return request(`/user?username=${username}&password=${password}&roleId=${roleId}&status=${status}&ssex=${ssex}&email=${email}&mobile=${mobile}&deptId=${deptId}`,{
        method:'post'
    })
}